package tests;

import java.awt.Color;

import graphics.Graphics3D;
import graphics.Zbuffer2;
import junit.framework.TestCase;
import classes.Matrix;

public class Graphics3DTest extends TestCase {

	Graphics3D G = new Graphics3D(new Zbuffer2(640, 480, Color.white));
	
	public void testPush() {
		Matrix	M = Matrix.translation(1f, 1f, 1f);
		G.push(M);
		
		assertTrue(G.getCamera().equals(M));
	}

	public void testPop() {
		Matrix	M = Matrix.translation(1f, 1f, 1f);
		G.push(M);
		assertTrue(G.getCamera().equals(M));
		G.pop();
		
		assertTrue(G.getCamera().equals(Matrix.identity()));
	}

	public void testGetCamera() {
		assertTrue(G.getCamera().equals(Matrix.identity()));
	}

	public void testSetCamera() {
		Matrix	M = Matrix.blank();
		G.setCamera(M);
		
		assertTrue(G.getCamera().equals(M));
	}

	public void testGetGraphics() {
		G.setGraphics(null);
		assertTrue(G.getGraphics()==null);
	}

	public void testSetGraphics() {
		G.setGraphics(null);
		assertTrue(G.getGraphics()==null);
	}

	public void testDrawLine() {
		fail("Not yet implemented");
	}

	public void testDrawPoly() {
		fail("Not yet implemented");
	}

	public void testFillPoly() {
		fail("Not yet implemented");
	}

	public void testRenderPoly() {
		fail("Not yet implemented");
	}

	public void testDrawShape() {
		fail("Not yet implemented");
	}

	public void testFillShape() {
		fail("Not yet implemented");
	}

	public void testRenderShape() {
		fail("Not yet implemented");
	}

}
